package com.xmim.core.session;


public interface SessionHandle<S extends Session, N> {


    default void handleAdded(SessionHandleContext ctx) throws Exception {

    }

    default void handleRemoved(SessionHandleContext ctx) throws Exception {

    }

    default void handleRead(SessionHandleContext ctx, Object msg) throws Exception {

    }

    default void handleClose(SessionHandleContext ctx) throws Exception {

    }

    default void handleHeartbeat(SessionHandleContext ctx, Object msg) throws Exception {

    }

    default void handleException(SessionHandleContext ctx, Throwable cause) {

    }

    default void handleReadComplete(SessionHandleContext ctx) throws Exception {

    }

    default void handleWriteComplete(SessionHandleContext ctx) throws Exception {

    }

}
